home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1993 July / InfoMagic USENET CD-ROM July 1993.ISO / sources / x / volume6 / xfig2 / patch4a < prev    next >
Encoding:
Internet Message Format  |  1993-04-28  |  54.9 KB

  1. From: envbvs@epb3.lbl.gov (Brian V. Smith)
  2. Newsgroups: comp.sources.x
  3. Subject: v06i034: xfig 2.0 patch 4 Part 1/3
  4. Message-ID: <132966@sun.Eng.Sun.COM>
  5. Date: 15 Mar 90 07:52:09 GMT
  6. Approved: argv@sun.com
  7.  
  8. Submitted-by: envbvs@epb3.lbl.gov (Brian V. Smith)
  9. Posting-number: Volume 6, Issue 34
  10. Archive-name: xfig2/patch4a
  11. Patch-To: xfig2: Volume 6, Issues 9-24
  12.  
  13. You are going to hate me, but here is *** part 1 of 3 *** of patch 4 for xfig.
  14. There were several bugs that people were complaining about, so I wanted
  15. to get these out as soon as I could.
  16.  
  17. Here is the part of the CHANGES file showing fixes and new features:
  18.  
  19. Patchlevel 4
  20. Changes from patchlevel 3:
  21.  
  22. o Bug fixed in drawing zero-length lines with arrows
  23. o Portrait/Landscape bug fixed (only appeared on Sun 4)
  24. o Fig will not allow edit of new figure without confirmation if
  25.     current figure has been modified
  26. o Widget resources work better now (e.g. xfig.form.indicator.background: green)
  27. o -ri option for button panel on right side works properly now
  28. o Changed some widget names for better resource hierarchy
  29. o Wrapped indicator widgets in box widget
  30. o Adds compatibility with Fig 1.4-TFX file format INSTEAD of 1.4X
  31.   as a compile time option (compiler flag -DTFX).  No change to program
  32.   as compiled without the -DTFX flag.  See file README.TFX.
  33.   Credit goes to Micah Beck for this one.
  34. o Fixed bug where scanf was doing %lf for text angle instead of %f
  35.   in read_textobject()
  36. o #include <X11/Scroll.h> put back in fig.h for R3 - XtRFloat is defined here
  37. o XtPointer is only defined in R4 - uses caddr_t for R3 blink() routine
  38. o User print to default printer, specify particular printer or print to file
  39. o Original FORMAT1.4 file included to compare new 1.4X format with 1.4
  40.   New file that describes xfig file format is called FORMAT1.4X
  41. o Drawing too-narrow ellipses doesn't loop forever anymore, but they
  42.   are still not drawn correctly
  43.  
  44. Thanks for posting these.
  45. Brian Smith
  46.  
  47. Part 1 of 3 follows -
  48.  
  49. #! /bin/sh
  50. # This is a shell archive.  Remove anything before this line, then unpack
  51. # it by saving it into a file and typing "sh file".  To overwrite existing
  52. # files, type "sh file -c".  You can also feed this as standard input via
  53. # unshar, or by typing "sh <file", e.g..  If this archive is complete, you
  54. # will see the following message at the end:
  55. #        "End of archive 1 (of 3)."
  56. # Contents:  CHANGES.diff blink.c.diff canvas.c.diff const.h.diff
  57. #   curve.c.diff draw.c.diff f2ps.c.diff fig.h.diff global.c.diff
  58. #   main.c.diff msgsw.c.diff panel2.h.diff patchlevel.h.diff
  59. #   popup.c.diff print.c.diff printfonts.c.diff psbits.c.diff
  60. #   psbits2.c.diff psfonts.c.diff psfonts.h.diff read.c.diff
  61. #   read1_3.c.diff resources.h.diff search.c.diff version.h.diff
  62. #   xtra.c.diff
  63. # Wrapped by envbvs@epb3.lbl.gov on Mon Mar 12 16:27:54 1990
  64. PATH=/bin:/usr/bin:/usr/ucb ; export PATH
  65. if test -f 'CHANGES.diff' -a "${1}" != "-c" ; then 
  66.   echo shar: Will not clobber existing file \"'CHANGES.diff'\"
  67. else
  68. echo shar: Extracting \"'CHANGES.diff'\" \(2342 characters\)
  69. sed "s/^X//" >'CHANGES.diff' <<'END_OF_FILE'
  70. X*** CHANGES.old    Fri Mar  9 11:17:06 1990
  71. X--- CHANGES    Mon Mar 12 16:20:50 1990
  72. X***************
  73. X*** 1,5
  74. X  Version 2.0 
  75. X  
  76. X  Patchlevel 3
  77. X  Changes from patchlevel 2:
  78. X  
  79. X
  80. X--- 1,30 -----
  81. X  Version 2.0 
  82. X  
  83. X+ Patchlevel 4
  84. X+ Changes from patchlevel 3:
  85. X+ 
  86. X+ o Bug fixed in drawing zero-length lines with arrows
  87. X+ o Portrait/Landscape bug fixed (only appeared on Sun 4)
  88. X+ o Fig will not allow edit of new figure without confirmation if
  89. X+     current figure has been modified
  90. X+ o Widget resources work better now (e.g. xfig.form.indicator.background: green)
  91. X+ o -ri option for button panel on right side works properly now
  92. X+ o Changed some widget names for better resource hierarchy
  93. X+ o Wrapped indicator widgets in box widget
  94. X+ o Adds compatibility with Fig 1.4-TFX file format INSTEAD of 1.4X
  95. X+   as a compile time option (compiler flag -DTFX).  No change to program
  96. X+   as compiled without the -DTFX flag.  See file README.TFX.
  97. X+   Credit goes to Micah Beck for this one.
  98. X+ o Fixed bug where scanf was doing %lf for text angle instead of %f
  99. X+   in read_textobject()
  100. X+ o #include <X11/Scroll.h> put back in fig.h for R3 - XtRFloat is defined here
  101. X+ o XtPointer is only defined in R4 - uses caddr_t for R3 blink() routine
  102. X+ o User print to default printer, specify particular printer or print to file
  103. X+ o Original FORMAT1.4 file included to compare new 1.4X format with 1.4
  104. X+   New file that describes xfig file format is called FORMAT1.4X
  105. X+ o Drawing too-narrow ellipses doesn't loop forever anymore, but they
  106. X+   are still not drawn correctly
  107. X+ 
  108. X  Patchlevel 3
  109. X  Changes from patchlevel 2:
  110. X  
  111. X***************
  112. X*** 4,9
  113. X  Changes from patchlevel 2:
  114. X  
  115. X  o now uses XtAddTimer instead of setitimer() for blinking cursor
  116. X  o Changed include directives for Athena widgets to include/X11/Xaw directory
  117. X  o added put_fmsg() to print messages with floating point numbers
  118. X    Some machines (MIPS) were dumping core when passing floats as ints.
  119. X
  120. X--- 29,35 -----
  121. X  Changes from patchlevel 2:
  122. X  
  123. X  o now uses XtAddTimer instead of setitimer() for blinking cursor
  124. X+   This fixes the problem with text freezing up xfig or crashing with core dump
  125. X  o Changed include directives for Athena widgets to include/X11/Xaw directory
  126. X  o added put_fmsg() to print messages with floating point numbers
  127. X    Some machines (MIPS) were dumping core when passing floats as ints.
  128. END_OF_FILE
  129. if test 2342 -ne `wc -c <'CHANGES.diff'`; then
  130.     echo shar: \"'CHANGES.diff'\" unpacked with wrong size!
  131. fi
  132. # end of 'CHANGES.diff'
  133. fi
  134. if test -f 'blink.c.diff' -a "${1}" != "-c" ; then 
  135.   echo shar: Will not clobber existing file \"'blink.c.diff'\"
  136. else
  137. echo shar: Extracting \"'blink.c.diff'\" \(717 characters\)
  138. sed "s/^X//" >'blink.c.diff' <<'END_OF_FILE'
  139. X*** blink.c.old    Wed Feb 28 13:45:22 1990
  140. X--- blink.c    Fri Mar  2 15:56:41 1990
  141. X***************
  142. X*** 41,49
  143. X      stop_blinking = FALSE;
  144. X      }
  145. X  
  146. X! turn_off_blinking_cursor(client_data,id)
  147. X! XtPointer client_data;
  148. X! XtIntervalId *id;
  149. X  {
  150. X      if (cursor_on) 
  151. X          erase(cursor_x, cursor_y);
  152. X
  153. X--- 41,47 -----
  154. X      stop_blinking = FALSE;
  155. X      }
  156. X  
  157. X! turn_off_blinking_cursor()
  158. X  {
  159. X      if (cursor_on) 
  160. X          erase(cursor_x, cursor_y);
  161. X***************
  162. X*** 51,57
  163. X      }
  164. X  
  165. X  static
  166. X! blink()
  167. X  {
  168. X      if (!stop_blinking)
  169. X          {
  170. X
  171. X--- 49,61 -----
  172. X      }
  173. X  
  174. X  static
  175. X! blink(client_data,id)
  176. X! #if XtSpecificationRelease >= 4
  177. X! XtPointer    client_data;
  178. X! #else
  179. X! caddr_t        client_data;
  180. X! #endif
  181. X! XtIntervalId    *id;
  182. X  {
  183. X      if (!stop_blinking)
  184. X          {
  185. END_OF_FILE
  186. if test 717 -ne `wc -c <'blink.c.diff'`; then
  187.     echo shar: \"'blink.c.diff'\" unpacked with wrong size!
  188. fi
  189. # end of 'blink.c.diff'
  190. fi
  191. if test -f 'canvas.c.diff' -a "${1}" != "-c" ; then 
  192.   echo shar: Will not clobber existing file \"'canvas.c.diff'\"
  193. else
  194. echo shar: Extracting \"'canvas.c.diff'\" \(905 characters\)
  195. sed "s/^X//" >'canvas.c.diff' <<'END_OF_FILE'
  196. X*** canvas.c.old    Tue Jan 16 17:21:03 1990
  197. X--- canvas.c    Wed Mar  7 11:47:11 1990
  198. X***************
  199. X*** 110,117
  200. X      
  201. X      canvas_args[3].value = CANVAS_WIDTH;
  202. X      canvas_args[4].value = CANVAS_HEIGHT;
  203. X!     canvas_args[5].value = (XtArgVal)panel_sw;
  204. X!     canvas_args[7].value = (XtArgVal)topruler_sw;
  205. X      canvas_sw = XtCreateWidget("canvas", labelWidgetClass, tool,
  206. X          canvas_args, XtNumber(canvas_args));
  207. X      XtGetValues(canvas_sw, canvas_color_args, XtNumber(canvas_color_args));
  208. X
  209. X--- 110,117 -----
  210. X      
  211. X      canvas_args[3].value = CANVAS_WIDTH;
  212. X      canvas_args[4].value = CANVAS_HEIGHT;
  213. X!     canvas_args[5].value = (XtArgVal)panel_sw;    /* to the right of the panel */
  214. X!     canvas_args[7].value = (XtArgVal)topruler_sw;    /* below the top ruler */
  215. X      canvas_sw = XtCreateWidget("canvas", labelWidgetClass, tool,
  216. X          canvas_args, XtNumber(canvas_args));
  217. X      XtGetValues(canvas_sw, canvas_color_args, XtNumber(canvas_color_args));
  218. END_OF_FILE
  219. if test 905 -ne `wc -c <'canvas.c.diff'`; then
  220.     echo shar: \"'canvas.c.diff'\" unpacked with wrong size!
  221. fi
  222. # end of 'canvas.c.diff'
  223. fi
  224. if test -f 'const.h.diff' -a "${1}" != "-c" ; then 
  225.   echo shar: Will not clobber existing file \"'const.h.diff'\"
  226. else
  227. echo shar: Extracting \"'const.h.diff'\" \(463 characters\)
  228. sed "s/^X//" >'const.h.diff' <<'END_OF_FILE'
  229. X*** const.h.old    Tue Jan 16 17:21:04 1990
  230. X--- const.h    Thu Mar  8 16:33:41 1990
  231. X***************
  232. X*** 28,33
  233. X  #define        SWITCH_ICON_HEIGHT    32
  234. X  #define        SWITCH_ICON_SPACING    4
  235. X  
  236. X! #define        MAXPRINTERS        2
  237. X  
  238. X  #define        DEF_PRINTFONTSIZE    12    /* default printer font size (points) */
  239. X
  240. X--- 28,33 -----
  241. X  #define        SWITCH_ICON_HEIGHT    32
  242. X  #define        SWITCH_ICON_SPACING    4
  243. X  
  244. X! #define        MAXPRINTERS        3
  245. X  
  246. X  #define        DEF_PRINTFONTSIZE    12    /* default printer font size (points) */
  247. END_OF_FILE
  248. if test 463 -ne `wc -c <'const.h.diff'`; then
  249.     echo shar: \"'const.h.diff'\" unpacked with wrong size!
  250. fi
  251. # end of 'const.h.diff'
  252. fi
  253. if test -f 'curve.c.diff' -a "${1}" != "-c" ; then 
  254.   echo shar: Will not clobber existing file \"'curve.c.diff'\"
  255. else
  256. echo shar: Extracting \"'curve.c.diff'\" \(1182 characters\)
  257. sed "s/^X//" >'curve.c.diff' <<'END_OF_FILE'
  258. X*** curve.c.old    Thu Feb 22 15:58:24 1990
  259. X--- curve.c    Fri Mar  9 10:56:32 1990
  260. X***************
  261. X*** 100,107
  262. X          x = x + deltax;  y = y + deltay;
  263. X          points[npoints].x = (short) xoff+x;
  264. X          points[npoints].y = (short) yoff-y;
  265. X!         if (npoints < MAXPTS)
  266. X!             npoints++;
  267. X          dfx = dfx + dfxx * deltax;
  268. X          dfy = dfy + dfyy * deltay;
  269. X          if (abs(x - xend) < margin && abs(y - yend) < margin) 
  270. X
  271. X--- 100,106 -----
  272. X          x = x + deltax;  y = y + deltay;
  273. X          points[npoints].x = (short) xoff+x;
  274. X          points[npoints].y = (short) yoff-y;
  275. X!         npoints++;
  276. X          dfx = dfx + dfxx * deltax;
  277. X          dfy = dfy + dfyy * deltay;
  278. X          if (abs(x - xend) < margin && abs(y - yend) < margin) 
  279. X***************
  280. X*** 106,112
  281. X          dfy = dfy + dfyy * deltay;
  282. X          if (abs(x - xend) < margin && abs(y - yend) < margin) 
  283. X          test_succeed--;
  284. X!         } while (test_succeed);
  285. X  
  286. X      if (margin == 1)    /* end points should touch */
  287. X          {
  288. X
  289. X--- 105,111 -----
  290. X          dfy = dfy + dfyy * deltay;
  291. X          if (abs(x - xend) < margin && abs(y - yend) < margin) 
  292. X          test_succeed--;
  293. X!         } while (test_succeed && npoints < MAXPTS);
  294. X  
  295. X      if (margin == 1)    /* end points should touch */
  296. X          {
  297. END_OF_FILE
  298. if test 1182 -ne `wc -c <'curve.c.diff'`; then
  299.     echo shar: \"'curve.c.diff'\" unpacked with wrong size!
  300. fi
  301. # end of 'curve.c.diff'
  302. fi
  303. if test -f 'draw.c.diff' -a "${1}" != "-c" ; then 
  304.   echo shar: Will not clobber existing file \"'draw.c.diff'\"
  305. else
  306. echo shar: Extracting \"'draw.c.diff'\" \(1331 characters\)
  307. sed "s/^X//" >'draw.c.diff' <<'END_OF_FILE'
  308. X*** draw.c.old    Fri Feb 16 11:00:46 1990
  309. X--- draw.c    Thu Mar  1 09:47:45 1990
  310. X***************
  311. X*** 199,204
  312. X  
  313. X      dx = x2 - x1;  dy = y1 - y2;
  314. X      l = sqrt((double)(dx*dx + dy*dy));
  315. X      sina = dy / l;  cosa = dx / l;
  316. X      xb = x2*cosa - y2*sina;
  317. X      yb = x2*sina + y2*cosa;
  318. X
  319. X--- 199,206 -----
  320. X  
  321. X      dx = x2 - x1;  dy = y1 - y2;
  322. X      l = sqrt((double)(dx*dx + dy*dy));
  323. X+     if(l == 0)
  324. X+         return;
  325. X      sina = dy / l;  cosa = dx / l;
  326. X      xb = x2*cosa - y2*sina;
  327. X      yb = x2*sina + y2*cosa;
  328. X***************
  329. X*** 330,335
  330. X          dx = x2 - x1;
  331. X          dy = y2 - y1;
  332. X          leng = sqrt((double)(dx*dx + dy*dy));
  333. X          if (leng <= dash_length) {
  334. X              pw_vector(canvas_pixwin, x1, y1, x2, y2, op, thick);
  335. X              break;
  336. X
  337. X--- 332,339 -----
  338. X          dx = x2 - x1;
  339. X          dy = y2 - y1;
  340. X          leng = sqrt((double)(dx*dx + dy*dy));
  341. X+         if(leng == 0)
  342. X+             break;
  343. X          if (leng <= dash_length) {
  344. X              pw_vector(canvas_pixwin, x1, y1, x2, y2, op, thick);
  345. X              break;
  346. X***************
  347. X*** 373,378
  348. X              pw_put(canvas_pixwin, x2, y2, color, thick);
  349. X              break;
  350. X              }
  351. X          dot_gap = leng / n;
  352. X          gap_x = dot_gap * dx / leng;
  353. X          gap_y = dot_gap * dy / leng;
  354. X
  355. X--- 377,384 -----
  356. X              pw_put(canvas_pixwin, x2, y2, color, thick);
  357. X              break;
  358. X              }
  359. X+         if(leng == 0)
  360. X+             break;
  361. X          dot_gap = leng / n;
  362. X          gap_x = dot_gap * dx / leng;
  363. X          gap_y = dot_gap * dy / leng;
  364. END_OF_FILE
  365. if test 1331 -ne `wc -c <'draw.c.diff'`; then
  366.     echo shar: \"'draw.c.diff'\" unpacked with wrong size!
  367. fi
  368. # end of 'draw.c.diff'
  369. fi
  370. if test -f 'f2ps.c.diff' -a "${1}" != "-c" ; then 
  371.   echo shar: Will not clobber existing file \"'f2ps.c.diff'\"
  372. else
  373. echo shar: Extracting \"'f2ps.c.diff'\" \(935 characters\)
  374. sed "s/^X//" >'f2ps.c.diff' <<'END_OF_FILE'
  375. X*** f2ps.c.old    Tue Feb 20 15:51:24 1990
  376. X--- f2ps.c    Fri Mar  2 13:06:01 1990
  377. X***************
  378. X*** 14,22
  379. X  #include "resources.h"
  380. X  #include "psfonts.h"
  381. X  
  382. X- #undef cfree
  383. X- #undef free
  384. X- 
  385. X  #define        PAGE_WIDTH        612    /* points; 8.5" */
  386. X  #define        PAGE_HEIGHT        792    /* points; 11" */
  387. X  #define        POINT_PER_INCH        72
  388. X
  389. X--- 14,19 -----
  390. X  #include "resources.h"
  391. X  #include "psfonts.h"
  392. X  
  393. X  #define        PAGE_WIDTH        612    /* points; 8.5" */
  394. X  #define        PAGE_HEIGHT        792    /* points; 11" */
  395. X  #define        POINT_PER_INCH        72
  396. X***************
  397. X*** 825,842
  398. X  {
  399. X      fprintf(stderr, format, arg1, arg2, arg3, arg4, arg5);
  400. X  }
  401. X- 
  402. X- #ifdef sparc
  403. X- 
  404. X- FREE ( x )    /*-- disable free --*/
  405. X-     char *x ;
  406. X- {
  407. X-     fprintf( stderr, "FREE -- %8x\n", x ) ;
  408. X- }
  409. X- CFREE ( x )   /*-- disable cfree --*/
  410. X-     char *x ;
  411. X- {
  412. X-     fprintf( stderr, "FREE -- %8x\n", x ) ;
  413. X- }
  414. X- 
  415. X- #endif  sparc
  416. X
  417. X--- 822,824 -----
  418. X  {
  419. X      fprintf(stderr, format, arg1, arg2, arg3, arg4, arg5);
  420. X  }
  421. END_OF_FILE
  422. if test 935 -ne `wc -c <'f2ps.c.diff'`; then
  423.     echo shar: \"'f2ps.c.diff'\" unpacked with wrong size!
  424. fi
  425. # end of 'f2ps.c.diff'
  426. fi
  427. if test -f 'fig.h.diff' -a "${1}" != "-c" ; then 
  428.   echo shar: Will not clobber existing file \"'fig.h.diff'\"
  429. else
  430. echo shar: Extracting \"'fig.h.diff'\" \(632 characters\)
  431. sed "s/^X//" >'fig.h.diff' <<'END_OF_FILE'
  432. X*** fig.h.old    Fri Mar  2 13:05:22 1990
  433. X--- fig.h    Fri Mar  2 16:10:16 1990
  434. X***************
  435. X*** 44,49
  436. X  #include <X11/Dialog.h>
  437. X  #include <X11/Box.h>
  438. X  #include <X11/Form.h>
  439. X  #endif
  440. X  
  441. X  #ifdef sparc
  442. X
  443. X--- 44,48 -----
  444. X  #include <X11/Dialog.h>
  445. X  #include <X11/Box.h>
  446. X  #include <X11/Form.h>
  447. X+ #include <X11/Scroll.h>        /* XtRFloat lives here! */
  448. X  #endif
  449. X***************
  450. X*** 45,54
  451. X  #include <X11/Box.h>
  452. X  #include <X11/Form.h>
  453. X  #endif
  454. X- 
  455. X- #ifdef sparc
  456. X- 
  457. X- #define free(x) FREE(x)
  458. X- #define cfree(x) CFREE(x)
  459. X- 
  460. X- #endif sparc
  461. X
  462. X--- 46,48 -----
  463. X  #include <X11/Form.h>
  464. X  #include <X11/Scroll.h>        /* XtRFloat lives here! */
  465. X  #endif
  466. END_OF_FILE
  467. if test 632 -ne `wc -c <'fig.h.diff'`; then
  468.     echo shar: \"'fig.h.diff'\" unpacked with wrong size!
  469. fi
  470. # end of 'fig.h.diff'
  471. fi
  472. if test -f 'global.c.diff' -a "${1}" != "-c" ; then 
  473.   echo shar: Will not clobber existing file \"'global.c.diff'\"
  474. else
  475. echo shar: Extracting \"'global.c.diff'\" \(1333 characters\)
  476. sed "s/^X//" >'global.c.diff' <<'END_OF_FILE'
  477. X*** global.c.old    Fri Feb 16 11:01:09 1990
  478. X--- global.c    Mon Mar 12 16:05:36 1990
  479. X***************
  480. X*** 97,104
  481. X  int            flip_axis        = -1;
  482. X  int            rotate_angle        = 0;
  483. X  int            fill_mode        = 0;
  484. X! int            landscape        = 1;
  485. X! int            print_landscape        = 1;    /* def. orientation for printer */
  486. X  int            size_button;            /* font size button value */
  487. X  int            font_button        = 0;    /* font button value */
  488. X  int            type_button        = T_LEFT_JUSTIFIED;    /* text type button value */
  489. X
  490. X--- 97,104 -----
  491. X  int            flip_axis        = -1;
  492. X  int            rotate_angle        = 0;
  493. X  int            fill_mode        = 0;
  494. X! int            landscape        = 0;
  495. X! int            print_landscape        = 0;    /* def. orientation for printer */
  496. X  int            size_button;            /* font size button value */
  497. X  int            font_button        = 0;    /* font button value */
  498. X  int            type_button        = T_LEFT_JUSTIFIED;    /* text type button value */
  499. X***************
  500. X*** 139,145
  501. X  char            current_file[200] = "";
  502. X  int            cur_printer=0;
  503. X  char            *printer="";
  504. X! char            *printer_list[MAXPRINTERS]={"at6","ap5"};
  505. X  int            figure_modified = 0;
  506. X  
  507. X  /************************  Error messages  ****************************/
  508. X
  509. X--- 139,145 -----
  510. X  char            current_file[200] = "";
  511. X  int            cur_printer=0;
  512. X  char            *printer="";
  513. X! char            *printer_list[MAXPRINTERS]={"Specify","Default","File"};
  514. X  int            figure_modified = 0;
  515. X  
  516. X  /************************  Error messages  ****************************/
  517. END_OF_FILE
  518. if test 1333 -ne `wc -c <'global.c.diff'`; then
  519.     echo shar: \"'global.c.diff'\" unpacked with wrong size!
  520. fi
  521. # end of 'global.c.diff'
  522. fi
  523. if test -f 'main.c.diff' -a "${1}" != "-c" ; then 
  524.   echo shar: Will not clobber existing file \"'main.c.diff'\"
  525. else
  526. echo shar: Extracting \"'main.c.diff'\" \(4437 characters\)
  527. sed "s/^X//" >'main.c.diff' <<'END_OF_FILE'
  528. X*** main.c.old    Tue Feb 20 10:59:26 1990
  529. X--- main.c    Mon Mar 12 16:05:06 1990
  530. X***************
  531. X*** 123,129
  532. X      int        argc;
  533. X      char        *argv[];
  534. X  {
  535. X! #define    NCHILDREN    10
  536. X      TOOL        form, children[NCHILDREN];
  537. X      Arg        tmp_arg[2];
  538. X      int        ichild;
  539. X
  540. X--- 123,129 -----
  541. X      int        argc;
  542. X      char        *argv[];
  543. X  {
  544. X! #define    NCHILDREN    8
  545. X      TOOL        form, children[NCHILDREN];
  546. X      Arg        tmp_arg[4];
  547. X      int        ichild;
  548. X***************
  549. X*** 125,131
  550. X  {
  551. X  #define    NCHILDREN    10
  552. X      TOOL        form, children[NCHILDREN];
  553. X!     Arg        tmp_arg[2];
  554. X      int        ichild;
  555. X      char        tstr[10];
  556. X      XWMHints    *wmhints;
  557. X
  558. X--- 125,131 -----
  559. X  {
  560. X  #define    NCHILDREN    8
  561. X      TOOL        form, children[NCHILDREN];
  562. X!     Arg        tmp_arg[4];
  563. X      int        ichild;
  564. X      char        tstr[10];
  565. X      XWMHints    *wmhints;
  566. X***************
  567. X*** 149,156
  568. X      if (argc > 1)
  569. X          file = argv[1];
  570. X  
  571. X!     if (landscape==0)        /* match print and screen format to start */
  572. X!         print_landscape=0;
  573. X  
  574. X      tool_d = XtDisplay(tool);
  575. X      tool_s = XtScreen(tool);
  576. X
  577. X--- 149,155 -----
  578. X      if (argc > 1)
  579. X          file = argv[1];
  580. X  
  581. X!     print_landscape = landscape;    /* match print and screen format to start */
  582. X  
  583. X      tool_d = XtDisplay(tool);
  584. X      tool_s = XtScreen(tool);
  585. X***************
  586. X*** 238,246
  587. X      children[ichild++] = msg_sw;        /* message window */
  588. X      children[ichild++] = sideruler_sw;    /* side ruler */
  589. X      children[ichild++] = panel2_sw;        /* lower button panel */
  590. X!     children[ichild++] = fill_panel;    /* current fill pattern window */
  591. X!     children[ichild++] = line_thick_panel;    /* current line thickness window */
  592. X!     children[ichild++] = radius_panel;    /* current arc-corner box radius window */
  593. X  
  594. X      /* until the following XtRealizeWidget() is called, there
  595. X         are NO windows in existence */
  596. X
  597. X--- 237,243 -----
  598. X      children[ichild++] = msg_sw;        /* message window */
  599. X      children[ichild++] = sideruler_sw;    /* side ruler */
  600. X      children[ichild++] = panel2_sw;        /* lower button panel */
  601. X!     children[ichild++] = ind_box;        /* fill/line/radius indicators */
  602. X  
  603. X      /* until the following XtRealizeWidget() is called, there
  604. X         are NO windows in existence */
  605. X***************
  606. X*** 254,260
  607. X      wmhints->input = True;
  608. X      XSetWMHints(tool_d, XtWindow(tool),wmhints);
  609. X  
  610. X!     if( RHS_PANEL )
  611. X      {
  612. X          XtSetArg(tmp_arg[0], XtNfromHoriz, 0);
  613. X          XtSetArg(tmp_arg[1], XtNhorizDistance, RULER_WIDTH+2);
  614. X
  615. X--- 251,257 -----
  616. X      wmhints->input = True;
  617. X      XSetWMHints(tool_d, XtWindow(tool),wmhints);
  618. X  
  619. X!     if( RHS_PANEL )        /* side button panel is on right size */
  620. X      {
  621. X          XtSetArg(tmp_arg[0], XtNfromHoriz, 0);
  622. X          XtSetArg(tmp_arg[1], XtNhorizDistance, RULER_WIDTH+2);
  623. X***************
  624. X*** 267,273
  625. X          XtSetArg(tmp_arg[1], XtNfromVert, topruler_sw);
  626. X          XtSetValues(canvas_sw, tmp_arg, 2);
  627. X          XtManageChild(msg_sw);
  628. X!         XtSetArg(tmp_arg[0], XtNfromHoriz, canvas_sw);
  629. X          XtSetArg(tmp_arg[1], XtNfromVert, 0);
  630. X          XtSetValues(panel_sw, tmp_arg, 2);
  631. X          XtSetArg(tmp_arg[0], XtNfromHoriz, sideruler_sw);
  632. X
  633. X--- 264,273 -----
  634. X          XtSetArg(tmp_arg[1], XtNfromVert, topruler_sw);
  635. X          XtSetValues(canvas_sw, tmp_arg, 2);
  636. X          XtManageChild(msg_sw);
  637. X! 
  638. X!         /* relocate the side button panel */
  639. X!         XtUnmanageChild(panel_sw);
  640. X!         XtSetArg(tmp_arg[0], XtNfromHoriz, canvas_sw); /* panel right of canvas */
  641. X          XtSetArg(tmp_arg[1], XtNfromVert, 0);
  642. X          XtSetArg(tmp_arg[2], XtNleft, XtChainRight);  /* chain to right of form */
  643. X          XtSetArg(tmp_arg[3], XtNright, XtChainRight);
  644. X***************
  645. X*** 269,280
  646. X          XtManageChild(msg_sw);
  647. X          XtSetArg(tmp_arg[0], XtNfromHoriz, canvas_sw);
  648. X          XtSetArg(tmp_arg[1], XtNfromVert, 0);
  649. X!         XtSetValues(panel_sw, tmp_arg, 2);
  650. X!         XtSetArg(tmp_arg[0], XtNfromHoriz, sideruler_sw);
  651. X!         XtSetArg(tmp_arg[1], XtNfromVert, canvas_sw);
  652. X!         XtSetValues(msg_sw, tmp_arg, 2);
  653. X!         XtUnmanageChild(msg_sw);
  654. X!         XtManageChild(msg_sw);
  655. X      }
  656. X  
  657. X      init_gc();
  658. X
  659. X--- 269,286 -----
  660. X          XtUnmanageChild(panel_sw);
  661. X          XtSetArg(tmp_arg[0], XtNfromHoriz, canvas_sw); /* panel right of canvas */
  662. X          XtSetArg(tmp_arg[1], XtNfromVert, 0);
  663. X!         XtSetArg(tmp_arg[2], XtNleft, XtChainRight);  /* chain to right of form */
  664. X!         XtSetArg(tmp_arg[3], XtNright, XtChainRight);
  665. X!         XtSetValues(panel_sw, tmp_arg, 4);
  666. X!         XtManageChild(panel_sw);
  667. X! 
  668. X!         /* relocate the indicator panel */
  669. X!         XtUnmanageChild(ind_box);
  670. X!         XtSetArg(tmp_arg[0], XtNfromHoriz, canvas_sw); /* right of canvas */
  671. X!         XtSetArg(tmp_arg[1], XtNleft, XtChainRight);  /* chain to right of form */
  672. X!         XtSetArg(tmp_arg[2], XtNright, XtChainRight);
  673. X!         XtSetValues(ind_box, tmp_arg, 3);
  674. X!         XtManageChild(ind_box);
  675. X      }
  676. X  
  677. X      init_gc();
  678. END_OF_FILE
  679. if test 4437 -ne `wc -c <'main.c.diff'`; then
  680.     echo shar: \"'main.c.diff'\" unpacked with wrong size!
  681. fi
  682. # end of 'main.c.diff'
  683. fi
  684. if test -f 'msgsw.c.diff' -a "${1}" != "-c" ; then 
  685.   echo shar: Will not clobber existing file \"'msgsw.c.diff'\"
  686. else
  687. echo shar: Extracting \"'msgsw.c.diff'\" \(853 characters\)
  688. sed "s/^X//" >'msgsw.c.diff' <<'END_OF_FILE'
  689. X*** msgsw.c.old    Wed Mar  7 10:01:35 1990
  690. X--- msgsw.c    Wed Mar  7 10:01:07 1990
  691. X***************
  692. X*** 81,88
  693. X      TOOL        tool;
  694. X  {
  695. X      msg_args[2].value = PANEL_WID+CANVAS_WIDTH+SIDERULER_WIDTH-FONT_PANE_WIDTH;
  696. X!     msg_args[5].value = (XtArgVal)psfont;        /* to the right of font ind. */
  697. X!     msg_args[7].value = (XtArgVal)canvas_sw;    /* just below the canvas */
  698. X      msg_sw = XtCreateManagedWidget("message", commandWidgetClass, tool,
  699. X          msg_args, XtNumber(msg_args));
  700. X      return (1);
  701. X
  702. X--- 81,88 -----
  703. X      TOOL        tool;
  704. X  {
  705. X      msg_args[2].value = PANEL_WID+CANVAS_WIDTH+SIDERULER_WIDTH-FONT_PANE_WIDTH;
  706. X!     msg_args[5].value = (XtArgVal)psfont;      /* to the right of font ind. */
  707. X!     msg_args[7].value = (XtArgVal)canvas_sw;  /* just below the canvas */
  708. X      msg_sw = XtCreateManagedWidget("message", commandWidgetClass, tool,
  709. X          msg_args, XtNumber(msg_args));
  710. X      return (1);
  711. END_OF_FILE
  712. if test 853 -ne `wc -c <'msgsw.c.diff'`; then
  713.     echo shar: \"'msgsw.c.diff'\" unpacked with wrong size!
  714. fi
  715. # end of 'msgsw.c.diff'
  716. fi
  717. if test -f 'panel2.h.diff' -a "${1}" != "-c" ; then 
  718.   echo shar: Will not clobber existing file \"'panel2.h.diff'\"
  719. else
  720. echo shar: Extracting \"'panel2.h.diff'\" \(4685 characters\)
  721. sed "s/^X//" >'panel2.h.diff' <<'END_OF_FILE'
  722. X*** panel2.h.old    Mon Mar  5 10:15:18 1990
  723. X--- panel2.h    Mon Mar  5 10:08:35 1990
  724. X***************
  725. X*** 217,228
  726. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  727. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0xff,
  728. X      0x3f,0x00,0x00,0x00,0x20,0x00,0x00,0x20,0x00,0x00,0x00,0xe0,
  729. X!     0xff,0xff,0x3f,0x00,0x00,0x00,0x20,0x00,0x00,0x20,0x00,0x00,
  730. X!     0x00,0x20,0x00,0x07,0x20,0x00,0x00,0x00,0x20,0x00,0x07,0x10,
  731. X!     0x00,0x00,0x00,0x20,0x00,0x00,0x08,0x00,0x00,0x00,0xe0,0xff,
  732. X!     0xff,0x07,0x00,0x00,0x00,0x78,0x00,0x00,0x04,0x00,0x00,0x00,
  733. X!     0x48,0xfe,0xff,0x04,0x00,0x00,0x00,0x78,0x00,0x00,0x04,0x00,
  734. X!     0x00,0x00,0x40,0xfe,0xff,0x04,0x00,0x00,0x00,0x40,0x00,0x00,
  735. X      0x04,0x00,0x00,0x00,0xc0,0xff,0xff,0x07,0x00,0x00,0x00,0x00,
  736. X      0x07,0xc0,0x01,0x00,0x00,0x00,0x00,0x02,0x80,0x00,0x00,0x00,
  737. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0e,0xc0,0x00,
  738. X
  739. X--- 217,228 -----
  740. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  741. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0xff,
  742. X      0x3f,0x00,0x00,0x00,0x20,0x00,0x00,0x20,0x00,0x00,0x00,0xe0,
  743. X!     0xff,0xff,0x3f,0x00,0x00,0x00,0x20,0x00,0x00,0x20,0x0e,0xc0,
  744. X!     0x00,0x20,0x00,0x07,0x20,0x11,0x80,0x00,0x20,0x00,0x07,0x10,
  745. X!     0x01,0x80,0x00,0x20,0x00,0x00,0x08,0x01,0x87,0x00,0xe0,0xff,
  746. X!     0xff,0x07,0x8e,0x88,0x00,0x78,0x00,0x00,0x04,0x90,0x8f,0x00,
  747. X!     0x48,0xfe,0xff,0x04,0x90,0x80,0x00,0x78,0x00,0x00,0x04,0x91,
  748. X!     0x88,0x00,0x40,0xfe,0xff,0x04,0x0e,0xc7,0x05,0x40,0x00,0x00,
  749. X      0x04,0x00,0x00,0x00,0xc0,0xff,0xff,0x07,0x00,0x00,0x00,0x00,
  750. X      0x07,0xc0,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  751. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  752. X***************
  753. X*** 224,236
  754. X      0x48,0xfe,0xff,0x04,0x00,0x00,0x00,0x78,0x00,0x00,0x04,0x00,
  755. X      0x00,0x00,0x40,0xfe,0xff,0x04,0x00,0x00,0x00,0x40,0x00,0x00,
  756. X      0x04,0x00,0x00,0x00,0xc0,0xff,0xff,0x07,0x00,0x00,0x00,0x00,
  757. X!     0x07,0xc0,0x01,0x00,0x00,0x00,0x00,0x02,0x80,0x00,0x00,0x00,
  758. X!     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0e,0xc0,0x00,
  759. X!     0x00,0x00,0x00,0x00,0x11,0x80,0x00,0x00,0x04,0x00,0x00,0x01,
  760. X!     0x80,0x00,0x00,0x04,0x00,0x00,0x01,0x87,0x70,0x38,0x1e,0x00,
  761. X!     0x00,0x8e,0x88,0x88,0x44,0x04,0x00,0x00,0x90,0x8f,0xf8,0x04,
  762. X!     0x04,0x00,0x00,0x90,0x80,0x08,0x04,0x04,0x00,0x00,0x91,0x88,
  763. X!     0x88,0x44,0x24,0x00,0x00,0x0e,0xc7,0x71,0x38,0x18,0x00,0x00,
  764. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  765. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00};
  766. X  mpr_static(print_sel_ic, 54, 32, 1, print_sel_image);
  767. X
  768. X--- 224,230 -----
  769. X      0x48,0xfe,0xff,0x04,0x90,0x80,0x00,0x78,0x00,0x00,0x04,0x91,
  770. X      0x88,0x00,0x40,0xfe,0xff,0x04,0x0e,0xc7,0x05,0x40,0x00,0x00,
  771. X      0x04,0x00,0x00,0x00,0xc0,0xff,0xff,0x07,0x00,0x00,0x00,0x00,
  772. X!     0x07,0xc0,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  773. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  774. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  775. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  776. X***************
  777. X*** 232,237
  778. X      0x04,0x00,0x00,0x90,0x80,0x08,0x04,0x04,0x00,0x00,0x91,0x88,
  779. X      0x88,0x44,0x24,0x00,0x00,0x0e,0xc7,0x71,0x38,0x18,0x00,0x00,
  780. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  781. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00};
  782. X  mpr_static(print_sel_ic, 54, 32, 1, print_sel_image);
  783. X  
  784. X
  785. X--- 226,237 -----
  786. X      0x04,0x00,0x00,0x00,0xc0,0xff,0xff,0x07,0x00,0x00,0x00,0x00,
  787. X      0x07,0xc0,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  788. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  789. X+     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  790. X+     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  791. X+     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  792. X+     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  793. X+     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  794. X+     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  795. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00};
  796. X  mpr_static(print_sel_ic,54,32,1,print_sel_image);
  797. X  
  798. X***************
  799. X*** 233,239
  800. X      0x88,0x44,0x24,0x00,0x00,0x0e,0xc7,0x71,0x38,0x18,0x00,0x00,
  801. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  802. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00};
  803. X! mpr_static(print_sel_ic, 54, 32, 1, print_sel_image);
  804. X  
  805. X  static char size_image[224] = {
  806. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  807. X
  808. X--- 233,239 -----
  809. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  810. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  811. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00};
  812. X! mpr_static(print_sel_ic,54,32,1,print_sel_image);
  813. X  
  814. X  static char size_image[224] = {
  815. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  816. END_OF_FILE
  817. if test 4685 -ne `wc -c <'panel2.h.diff'`; then
  818.     echo shar: \"'panel2.h.diff'\" unpacked with wrong size!
  819. fi
  820. # end of 'panel2.h.diff'
  821. fi
  822. if test -f 'patchlevel.h.diff' -a "${1}" != "-c" ; then 
  823.   echo shar: Will not clobber existing file \"'patchlevel.h.diff'\"
  824. else
  825. echo shar: Extracting \"'patchlevel.h.diff'\" \(169 characters\)
  826. sed "s/^X//" >'patchlevel.h.diff' <<'END_OF_FILE'
  827. X*** patchlevel.h.old    Tue Feb 27 09:22:42 1990
  828. X--- patchlevel.h    Thu Mar  1 13:18:06 1990
  829. X***************
  830. X*** 1
  831. X! #define PATCHLEVEL 3
  832. X
  833. X--- 1 -----
  834. X! #define PATCHLEVEL 4
  835. END_OF_FILE
  836. if test 169 -ne `wc -c <'patchlevel.h.diff'`; then
  837.     echo shar: \"'patchlevel.h.diff'\" unpacked with wrong size!
  838. fi
  839. # end of 'patchlevel.h.diff'
  840. fi
  841. if test -f 'popup.c.diff' -a "${1}" != "-c" ; then 
  842.   echo shar: Will not clobber existing file \"'popup.c.diff'\"
  843. else
  844. echo shar: Extracting \"'popup.c.diff'\" \(776 characters\)
  845. sed "s/^X//" >'popup.c.diff' <<'END_OF_FILE'
  846. X*** popup.c.old    Fri Feb 16 11:01:22 1990
  847. X--- popup.c    Fri Mar  9 13:50:30 1990
  848. X***************
  849. X*** 185,194
  850. X          redisplay_canvas();
  851. X          break;
  852. X          case F_EDIT :
  853. X!         if (!no_object() && figure_modified) {
  854. X!             if (wmgr_confirm(canvas_swfd, edit_msg) != -1) break;
  855. X!             }
  856. X!         init_msg_receiving(edit_file, "Edit file : ");
  857. X          break;
  858. X          case F_PRINT:
  859. X          print_figure();
  860. X
  861. X--- 185,191 -----
  862. X          redisplay_canvas();
  863. X          break;
  864. X          case F_EDIT :
  865. X!         edit();
  866. X          break;
  867. X          case F_PRINT:
  868. X          print_figure();
  869. X***************
  870. X*** 256,258
  871. X          }
  872. X      }
  873. X  
  874. X
  875. X--- 253,262 -----
  876. X          }
  877. X      }
  878. X  
  879. X+ edit()
  880. X+     {
  881. X+     if (!no_object() && figure_modified)
  882. X+         if (wmgr_confirm(canvas_swfd, edit_msg) != -1) 
  883. X+         return;
  884. X+     init_msg_receiving(edit_file, "Edit file : ");
  885. X+     }
  886. END_OF_FILE
  887. if test 776 -ne `wc -c <'popup.c.diff'`; then
  888.     echo shar: \"'popup.c.diff'\" unpacked with wrong size!
  889. fi
  890. # end of 'popup.c.diff'
  891. fi
  892. if test -f 'print.c.diff' -a "${1}" != "-c" ; then 
  893.   echo shar: Will not clobber existing file \"'print.c.diff'\"
  894. else
  895. echo shar: Extracting \"'print.c.diff'\" \(4419 characters\)
  896. sed "s/^X//" >'print.c.diff' <<'END_OF_FILE'
  897. X*** print.c.old    Tue Jan 16 17:21:33 1990
  898. X--- print.c    Mon Mar  5 10:19:38 1990
  899. X***************
  900. X*** 27,35
  901. X          "Figure hasn't been saved, PRINT with LEFT button, CANCEL with MIDDLE or RIGHT";
  902. X  
  903. X  print_figure()
  904. X!     {
  905. X!     if (current_file[0]==0)
  906. X!         {
  907. X          put_msg("NO FILE TO PRINT");
  908. X          XBell(tool_d,50);
  909. X          }
  910. X
  911. X--- 27,36 -----
  912. X          "Figure hasn't been saved, PRINT with LEFT button, CANCEL with MIDDLE or RIGHT";
  913. X  
  914. X  print_figure()
  915. X! {
  916. X! int    print_to_specified_printer();
  917. X! int    print_to_file();
  918. X!     if (current_file[0]==0) {
  919. X          put_msg("NO FILE TO PRINT");
  920. X          XBell(tool_d,50);
  921. X      }
  922. X***************
  923. X*** 32,40
  924. X          {
  925. X          put_msg("NO FILE TO PRINT");
  926. X          XBell(tool_d,50);
  927. X!         }
  928. X!     else
  929. X!         {
  930. X          if (figure_modified)    /* modified without saving, confirm print */
  931. X              if (wmgr_confirm(canvas_swfd, conf_prnt) != -1)
  932. X              return;
  933. X
  934. X--- 33,40 -----
  935. X      if (current_file[0]==0) {
  936. X          put_msg("NO FILE TO PRINT");
  937. X          XBell(tool_d,50);
  938. X!     }
  939. X!     else {
  940. X          if (figure_modified)    /* modified without saving, confirm print */
  941. X              if (wmgr_confirm(canvas_swfd, conf_prnt) != -1)
  942. X              return;
  943. X***************
  944. X*** 38,44
  945. X          if (figure_modified)    /* modified without saving, confirm print */
  946. X              if (wmgr_confirm(canvas_swfd, conf_prnt) != -1)
  947. X              return;
  948. X!         put_msg("Print figure %s on printer %s in %s mode",
  949. X              current_file,printer,print_landscape? "LANDSCAPE":"PORTRAIT");
  950. X          sprintf(prcmd,"f2ps -c %s %s | lpr -J %s -P%s",
  951. X              print_landscape? "-L":"-P", 
  952. X
  953. X--- 38,46 -----
  954. X          if (figure_modified)    /* modified without saving, confirm print */
  955. X              if (wmgr_confirm(canvas_swfd, conf_prnt) != -1)
  956. X              return;
  957. X! 
  958. X!                 if (! strcmp("Default", printer)) {
  959. X!           put_msg("Print figure %s on printer %s in %s mode",
  960. X              current_file,printer,print_landscape? "LANDSCAPE":"PORTRAIT");
  961. X            sprintf(prcmd,"f2ps -c %s %s | lpr -J %s",
  962. X                print_landscape? "-L":"-P", 
  963. X***************
  964. X*** 40,50
  965. X              return;
  966. X          put_msg("Print figure %s on printer %s in %s mode",
  967. X              current_file,printer,print_landscape? "LANDSCAPE":"PORTRAIT");
  968. X!         sprintf(prcmd,"f2ps -c %s %s | lpr -J %s -P%s",
  969. X!             print_landscape? "-L":"-P", 
  970. X!             current_file,
  971. X!             current_file, 
  972. X!             printer);
  973. X          if (system(prcmd)==127)
  974. X              put_msg("Error in printing");
  975. X          }
  976. X
  977. X--- 42,65 -----
  978. X                  if (! strcmp("Default", printer)) {
  979. X            put_msg("Print figure %s on printer %s in %s mode",
  980. X              current_file,printer,print_landscape? "LANDSCAPE":"PORTRAIT");
  981. X!           sprintf(prcmd,"f2ps -c %s %s | lpr -J %s",
  982. X!               print_landscape? "-L":"-P", 
  983. X!               current_file,
  984. X!               current_file);
  985. X!         }
  986. X!                 else if (! strcmp("File", printer))
  987. X!                   init_msg_receiving(print_to_file, "Output file : ");
  988. X!                 else if (! strcmp("Specify", printer))
  989. X!                   init_msg_receiving(print_to_specified_printer, "Printer : ");
  990. X!                 else {    /* default */
  991. X!           put_msg("Print figure %s on printer %s in %s mode",
  992. X!             current_file,printer,print_landscape? "LANDSCAPE":"PORTRAIT");
  993. X!           sprintf(prcmd,"f2ps -c %s %s | lpr -J %s -P%s",
  994. X!             print_landscape? "-L":"-P", 
  995. X!             current_file,
  996. X!             current_file, 
  997. X!             printer);
  998. X!         }
  999. X          if (system(prcmd)==127)
  1000. X              put_msg("Error in printing");
  1001. X      }
  1002. X***************
  1003. X*** 47,51
  1004. X              printer);
  1005. X          if (system(prcmd)==127)
  1006. X              put_msg("Error in printing");
  1007. X-         }
  1008. X      }
  1009. X
  1010. X--- 62,67 -----
  1011. X          }
  1012. X          if (system(prcmd)==127)
  1013. X              put_msg("Error in printing");
  1014. X      }
  1015. X  }
  1016. X  
  1017. X***************
  1018. X*** 49,51
  1019. X              put_msg("Error in printing");
  1020. X          }
  1021. X      }
  1022. X
  1023. X--- 63,97 -----
  1024. X          if (system(prcmd)==127)
  1025. X              put_msg("Error in printing");
  1026. X      }
  1027. X+ }
  1028. X+ 
  1029. X+ print_to_file(file)
  1030. X+ char    *file;
  1031. X+ {
  1032. X+     if (*file == 0) {
  1033. X+         put_msg("Empty name");
  1034. X+         return;
  1035. X+         }
  1036. X+     sprintf(prcmd,"f2ps -c %s %s > %s",
  1037. X+         print_landscape? "-L":"-P",
  1038. X+         current_file,
  1039. X+         file);
  1040. X+     put_msg("Print figure %s to file %s in %s mode",
  1041. X+       current_file,file,print_landscape? "LANDSCAPE":"PORTRAIT");
  1042. X+ }
  1043. X+ 
  1044. X+ print_to_specified_printer(specified_printer)
  1045. X+ char    *specified_printer;
  1046. X+ {
  1047. X+     if (*specified_printer == 0) {
  1048. X+         put_msg("Empty name");
  1049. X+         return;
  1050. X+         }
  1051. X+     put_msg("Print figure %s on printer %s in %s mode",
  1052. X+       current_file,specified_printer,print_landscape? "LANDSCAPE":"PORTRAIT");
  1053. X+     sprintf(prcmd,"f2ps -c %s %s | lpr -J %s -P%s",
  1054. X+       print_landscape? "-L":"-P", 
  1055. X+       current_file,
  1056. X+       current_file, 
  1057. X+       specified_printer);
  1058. X+ }
  1059. END_OF_FILE
  1060. if test 4419 -ne `wc -c <'print.c.diff'`; then
  1061.     echo shar: \"'print.c.diff'\" unpacked with wrong size!
  1062. fi
  1063. # end of 'print.c.diff'
  1064. fi
  1065. if test -f 'printfonts.c.diff' -a "${1}" != "-c" ; then 
  1066.   echo shar: Will not clobber existing file \"'printfonts.c.diff'\"
  1067. else
  1068. echo shar: Extracting \"'printfonts.c.diff'\" \(4167 characters\)
  1069. sed "s/^X//" >'printfonts.c.diff' <<'END_OF_FILE'
  1070. X*** printfonts.c.old    Tue Jan 16 17:22:08 1990
  1071. X--- printfonts.c    Fri Mar  9 16:48:55 1990
  1072. X***************
  1073. X*** 76,83
  1074. X      /* 1 */ { XtNy, (XtArgVal)0 },
  1075. X      /* 2 */ { XtNwidth, (XtArgVal) FONT_PANE_WIDTH },
  1076. X      /* 3 */ { XtNheight, (XtArgVal) MSG_HEIGHT },    /* same height as message panel */
  1077. X!     /* 4 */ { XtNfromHoriz, (XtArgVal) NULL },    /* flush with panel indicator */
  1078. X!     /* 5 */ { XtNhorizDistance, (XtArgVal) -3*SWITCH_ICON_WIDTH-6*SWITCH_ICON_SPACING },
  1079. X      /* 6 */ { XtNfromVert, (XtArgVal) NULL },
  1080. X      /* 7 */ { XtNvertDistance, (XtArgVal) 1 },    /* dist from canvas_sw window */
  1081. X      /* 8 */ { XtNbitmap, (XtArgVal) NULL },
  1082. X
  1083. X--- 76,83 -----
  1084. X      /* 1 */ { XtNy, (XtArgVal)0 },
  1085. X      /* 2 */ { XtNwidth, (XtArgVal) FONT_PANE_WIDTH },
  1086. X      /* 3 */ { XtNheight, (XtArgVal) MSG_HEIGHT },    /* same height as message panel */
  1087. X!     /* 4 */ { XtNfromHoriz, (XtArgVal) NULL },    /* left side of main form */
  1088. X!     /* 5 */ { XtNhorizDistance, (XtArgVal) SWITCH_ICON_SPACING },
  1089. X      /* 6 */ { XtNfromVert, (XtArgVal) NULL },
  1090. X      /* 7 */ { XtNvertDistance, (XtArgVal) 1 },    /* dist from canvas_sw window */
  1091. X      /* 8 */ { XtNbitmap, (XtArgVal) NULL },
  1092. X***************
  1093. X*** 99,105
  1094. X      XtTranslations        popdown_actions, pane_actions;
  1095. X      Arg            my_list;
  1096. X  
  1097. X!     fontmenu = XtCreatePopupShell("popup_menu", overrideShellWidgetClass, tool,
  1098. X          fontmenu_args, XtNumber(fontmenu_args));
  1099. X      popdown_actions = XtParseTranslationTable(
  1100. X          "<Btn1Up>:MenuPopdown()\n");
  1101. X
  1102. X--- 99,105 -----
  1103. X      XtTranslations        popdown_actions, pane_actions;
  1104. X      Arg            my_list;
  1105. X  
  1106. X!     fontmenu = XtCreatePopupShell("font_menu", overrideShellWidgetClass, tool,
  1107. X          fontmenu_args, XtNumber(fontmenu_args));
  1108. X      popdown_actions = XtParseTranslationTable(
  1109. X          "<Btn1Up>:MenuPopdown()\n");
  1110. X***************
  1111. X*** 130,135
  1112. X                       fontpanes, pane_args, XtNumber(pane_args));
  1113. X      XtOverrideTranslations(fontpane[0], pane_actions);
  1114. X  
  1115. X      for (i = 1; i < NUMFONTS; ++i)
  1116. X      {
  1117. X          mi = &fontmenu_items[i];
  1118. X
  1119. X--- 130,136 -----
  1120. X                       fontpanes, pane_args, XtNumber(pane_args));
  1121. X      XtOverrideTranslations(fontpane[0], pane_actions);
  1122. X  
  1123. X+ 
  1124. X      for (i = 1; i < NUMFONTS; ++i)
  1125. X      {
  1126. X          mi = &fontmenu_items[i];
  1127. X***************
  1128. X*** 142,148
  1129. X      /* Now set up the font indicator window */
  1130. X  
  1131. X      /* position */
  1132. X-     psfont_args[4].value = (XtArgVal)panel_sw;    /* flush left with panel window */
  1133. X      psfont_args[6].value = (XtArgVal)canvas_sw;    /* just below the canvas window */
  1134. X      psfont = XtCreateManagedWidget("indicator", labelWidgetClass, tool,
  1135. X          psfont_args, XtNumber(psfont_args));
  1136. X
  1137. X--- 143,148 -----
  1138. X      /* Now set up the font indicator window */
  1139. X  
  1140. X      /* position */
  1141. X      psfont_args[6].value = (XtArgVal)canvas_sw;    /* just below the canvas window */
  1142. X      psfont = XtCreateManagedWidget("font_indicator", labelWidgetClass, tool,
  1143. X          psfont_args, XtNumber(psfont_args));
  1144. X***************
  1145. X*** 144,150
  1146. X      /* position */
  1147. X      psfont_args[4].value = (XtArgVal)panel_sw;    /* flush left with panel window */
  1148. X      psfont_args[6].value = (XtArgVal)canvas_sw;    /* just below the canvas window */
  1149. X!     psfont = XtCreateManagedWidget("indicator", labelWidgetClass, tool,
  1150. X          psfont_args, XtNumber(psfont_args));
  1151. X      return (1);
  1152. X  }
  1153. X
  1154. X--- 144,150 -----
  1155. X  
  1156. X      /* position */
  1157. X      psfont_args[6].value = (XtArgVal)canvas_sw;    /* just below the canvas window */
  1158. X!     psfont = XtCreateManagedWidget("font_indicator", labelWidgetClass, tool,
  1159. X          psfont_args, XtNumber(psfont_args));
  1160. X      return (1);
  1161. X  }
  1162. X***************
  1163. X*** 159,167
  1164. X      /* Create the bitmaps */
  1165. X  
  1166. X      for (i=0; i<NUMFONTS; i++)
  1167. X!         font_menu_bitmaps[i] = XCreatePixmapFromBitmapData(tool_d, XtWindow(psfont),
  1168. X!         font_menu_bits[i], FONT_PANE_WIDTH, FONT_PANE_HEIGHT,
  1169. X!         x_bg_color.pixel, x_fg_color.pixel, DefaultDepthOfScreen(tool_s));
  1170. X      psfont_args[8].value = (XtArgVal) font_menu_bitmaps[0];
  1171. X      XtSetValues(psfont, &psfont_args[8], 1);    /* show default font in window */
  1172. X  
  1173. X
  1174. X--- 159,166 -----
  1175. X      /* Create the bitmaps */
  1176. X  
  1177. X      for (i=0; i<NUMFONTS; i++)
  1178. X!         font_menu_bitmaps[i] = XCreateBitmapFromData(tool_d,XtWindow(psfont),
  1179. X!         font_menu_bits[i], FONT_PANE_WIDTH, FONT_PANE_HEIGHT);
  1180. X      psfont_args[8].value = (XtArgVal) font_menu_bitmaps[0];
  1181. X      XtSetValues(psfont, &psfont_args[8], 1);    /* show default font in window */
  1182. X  
  1183. END_OF_FILE
  1184. if test 4167 -ne `wc -c <'printfonts.c.diff'`; then
  1185.     echo shar: \"'printfonts.c.diff'\" unpacked with wrong size!
  1186. fi
  1187. # end of 'printfonts.c.diff'
  1188. fi
  1189. if test -f 'psbits.c.diff' -a "${1}" != "-c" ; then 
  1190.   echo shar: Will not clobber existing file \"'psbits.c.diff'\"
  1191. else
  1192. echo shar: Extracting \"'psbits.c.diff'\" \(1490 characters\)
  1193. sed "s/^X//" >'psbits.c.diff' <<'END_OF_FILE'
  1194. X*** psbits.c.old    Mon Feb 19 11:26:16 1990
  1195. X--- psbits.c    Fri Mar  2 11:51:20 1990
  1196. X***************
  1197. X*** 11,16
  1198. X  */
  1199. X  
  1200. X  /* These are the bitmaps for the font menu panes */
  1201. X  /* Part 1 of 3 */
  1202. X  
  1203. X  #include <X11/Xlib.h>
  1204. X
  1205. X--- 11,18 -----
  1206. X  */
  1207. X  
  1208. X  /* These are the bitmaps for the font menu panes */
  1209. X+ 
  1210. X+ 
  1211. X  /* Part 1 of 3 */
  1212. X  
  1213. X  #include <X11/Xlib.h>
  1214. X***************
  1215. X*** 16,21
  1216. X  #include <X11/Xlib.h>
  1217. X  #include "psfonts.h"
  1218. X  
  1219. X  static char AvantGarde_BookOblique_bits[] = {
  1220. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  1221. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  1222. X
  1223. X--- 18,24 -----
  1224. X  #include <X11/Xlib.h>
  1225. X  #include "psfonts.h"
  1226. X  
  1227. X+ #ifndef TFX
  1228. X  static char AvantGarde_BookOblique_bits[] = {
  1229. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  1230. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  1231. X***************
  1232. X*** 772,777
  1233. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  1234. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  1235. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 };
  1236. X  
  1237. X  /* get part 2 */
  1238. X  #include "psbits2.c"
  1239. X
  1240. X--- 775,781 -----
  1241. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  1242. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  1243. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 };
  1244. X+ #endif
  1245. X  
  1246. X  /* get part 2 */
  1247. X  #include "psbits2.c"
  1248. X***************
  1249. X*** 775,777
  1250. X  
  1251. X  /* get part 2 */
  1252. X  #include "psbits2.c"
  1253. X
  1254. X--- 779,782 -----
  1255. X  
  1256. X  /* get part 2 */
  1257. X  #include "psbits2.c"
  1258. X+ 
  1259. END_OF_FILE
  1260. if test 1490 -ne `wc -c <'psbits.c.diff'`; then
  1261.     echo shar: \"'psbits.c.diff'\" unpacked with wrong size!
  1262. fi
  1263. # end of 'psbits.c.diff'
  1264. fi
  1265. if test -f 'psbits2.c.diff' -a "${1}" != "-c" ; then 
  1266.   echo shar: Will not clobber existing file \"'psbits2.c.diff'\"
  1267. else
  1268. echo shar: Extracting \"'psbits2.c.diff'\" \(1125 characters\)
  1269. sed "s/^X//" >'psbits2.c.diff' <<'END_OF_FILE'
  1270. X*** psbits2.c.old    Mon Feb 19 11:29:21 1990
  1271. X--- psbits2.c    Fri Mar  2 11:51:52 1990
  1272. X***************
  1273. X*** 13,18
  1274. X  /* These are the bitmaps for the font menu panes */
  1275. X  /* Part 2 of 3 */
  1276. X  
  1277. X  static char Helvetica_Bold_bits[] = {
  1278. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  1279. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  1280. X
  1281. X--- 13,19 -----
  1282. X  /* These are the bitmaps for the font menu panes */
  1283. X  /* Part 2 of 3 */
  1284. X  
  1285. X+ #ifndef TFX
  1286. X  static char Helvetica_Bold_bits[] = {
  1287. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  1288. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  1289. X***************
  1290. X*** 769,774
  1291. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  1292. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  1293. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 };
  1294. X  
  1295. X  /* get part 3 */
  1296. X  #include "psbits3.c" 
  1297. X
  1298. X--- 770,776 -----
  1299. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  1300. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  1301. X      0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 };
  1302. X+ #endif
  1303. X  
  1304. X  /* get part 3 */
  1305. X  #include "psbits3.c" 
  1306. END_OF_FILE
  1307. if test 1125 -ne `wc -c <'psbits2.c.diff'`; then
  1308.     echo shar: \"'psbits2.c.diff'\" unpacked with wrong size!
  1309. fi
  1310. # end of 'psbits2.c.diff'
  1311. fi
  1312. if test -f 'psfonts.c.diff' -a "${1}" != "-c" ; then 
  1313.   echo shar: Will not clobber existing file \"'psfonts.c.diff'\"
  1314. else
  1315. echo shar: Extracting \"'psfonts.c.diff'\" \(2154 characters\)
  1316. sed "s/^X//" >'psfonts.c.diff' <<'END_OF_FILE'
  1317. X*** psfonts.c.old    Tue Jan 16 17:22:33 1990
  1318. X--- psfonts.c    Wed Mar  7 16:08:01 1990
  1319. X***************
  1320. X*** 1,5
  1321. X  #include <X11/Xlib.h>
  1322. X  #include "psfonts.h"
  1323. X  #define NULL 0
  1324. X  
  1325. X  /* printer font names for indicator window */
  1326. X
  1327. X--- 1,6 -----
  1328. X  #include <X11/Xlib.h>
  1329. X  #include "psfonts.h"
  1330. X+ 
  1331. X  #define NULL 0
  1332. X  
  1333. X  /* printer font names for indicator window */
  1334. X***************
  1335. X*** 4,9
  1336. X  
  1337. X  /* printer font names for indicator window */
  1338. X  
  1339. X  struct _fstruct fontnames[NUMFONTS] = {
  1340. X       {"Times-Roman",        "-adobe-times-medium-r-*--*", NULL},
  1341. X       {"Times-Italic",        "-adobe-times-medium-i-*--*", NULL},
  1342. X
  1343. X--- 5,11 -----
  1344. X  
  1345. X  /* printer font names for indicator window */
  1346. X  
  1347. X+ #ifndef TFX
  1348. X  struct _fstruct fontnames[NUMFONTS] = {
  1349. X       {"Times-Roman",        "-adobe-times-medium-r-*--*", NULL},
  1350. X       {"Times-Italic",        "-adobe-times-medium-i-*--*", NULL},
  1351. X***************
  1352. X*** 38,43
  1353. X       {"Palatino-Bold",        "NONE", NULL},
  1354. X       {"Palatino-BoldItalic",    "NONE", NULL},
  1355. X       {"Symbol",            "*-symbol-medium-r-*--*", NULL},
  1356. X!      {"ZapfChancery-MediumItalic",    "zapfchancery-mediumitalic--*", NULL},
  1357. X!      {"ZapfDingbats",        "zapfdingbats--*", NULL},
  1358. X       };
  1359. X
  1360. X--- 40,47 -----
  1361. X       {"Palatino-Bold",        "NONE", NULL},
  1362. X       {"Palatino-BoldItalic",    "NONE", NULL},
  1363. X       {"Symbol",            "*-symbol-medium-r-*--*", NULL},
  1364. X!      {"ZapfChancery-MediumItalic",    "-*-zapfchancery-medium-i-*--*", NULL},
  1365. X!      {"ZapfDingbats",        "-*-zapfdingbats-*-*-*--*", NULL},
  1366. X       };
  1367. X  #else
  1368. X  struct _fstruct fontnames[NUMFONTS] = {
  1369. X***************
  1370. X*** 41,43
  1371. X       {"ZapfChancery-MediumItalic",    "zapfchancery-mediumitalic--*", NULL},
  1372. X       {"ZapfDingbats",        "zapfdingbats--*", NULL},
  1373. X       };
  1374. X
  1375. X--- 43,55 -----
  1376. X       {"ZapfChancery-MediumItalic",    "-*-zapfchancery-medium-i-*--*", NULL},
  1377. X       {"ZapfDingbats",        "-*-zapfdingbats-*-*-*--*", NULL},
  1378. X       };
  1379. X+ #else
  1380. X+ struct _fstruct fontnames[NUMFONTS] = {
  1381. X+     {"Default",        "-adobe-times-medium-r-*--*", NULL},
  1382. X+     {"Roman",        "-adobe-times-medium-r-*--*", NULL},
  1383. X+     {"Bold",        "-adobe-times-bold-r-*--*", NULL},
  1384. X+     {"Italic",        "-adobe-times-medium-i-*--*", NULL},
  1385. X+     {"Modern",        "-adobe-helvetica-medium-r-*--*", NULL},
  1386. X+     {"Typewriter",        "-adobe-courier-medium-r-*--*", NULL},
  1387. X+            };
  1388. X+ #endif
  1389. END_OF_FILE
  1390. if test 2154 -ne `wc -c <'psfonts.c.diff'`; then
  1391.     echo shar: \"'psfonts.c.diff'\" unpacked with wrong size!
  1392. fi
  1393. # end of 'psfonts.c.diff'
  1394. fi
  1395. if test -f 'psfonts.h.diff' -a "${1}" != "-c" ; then 
  1396.   echo shar: Will not clobber existing file \"'psfonts.h.diff'\"
  1397. else
  1398. echo shar: Extracting \"'psfonts.h.diff'\" \(1156 characters\)
  1399. sed "s/^X//" >'psfonts.h.diff' <<'END_OF_FILE'
  1400. X*** psfonts.h.old    Tue Jan 16 17:22:18 1990
  1401. X--- psfonts.h    Fri Mar  2 12:05:46 1990
  1402. X***************
  1403. X*** 1,5
  1404. X- #define    FONT_PANE_WIDTH 290
  1405. X- #define    FONT_PANE_HEIGHT 20
  1406. X  #define    MIN_P_SIZE 6
  1407. X  #define    MAX_P_SIZE 30
  1408. X  #define    NUMFONTS 35
  1409. X
  1410. X--- 1,3 -----
  1411. X  #define    MIN_P_SIZE 6
  1412. X  #define    MAX_P_SIZE 30
  1413. X  
  1414. X***************
  1415. X*** 2,7
  1416. X  #define    FONT_PANE_HEIGHT 20
  1417. X  #define    MIN_P_SIZE 6
  1418. X  #define    MAX_P_SIZE 30
  1419. X  #define    NUMFONTS 35
  1420. X  
  1421. X  /* element of linked list for each font
  1422. X
  1423. X--- 1,9 -----
  1424. X  #define    MIN_P_SIZE 6
  1425. X  #define    MAX_P_SIZE 30
  1426. X+ 
  1427. X+ #ifndef TFX
  1428. X+ #define    FONT_PANE_WIDTH 290
  1429. X+ #define    FONT_PANE_HEIGHT 20
  1430. X  #define    NUMFONTS 35
  1431. X  #else
  1432. X  #define    FONT_PANE_WIDTH 112
  1433. X***************
  1434. X*** 3,8
  1435. X  #define    MIN_P_SIZE 6
  1436. X  #define    MAX_P_SIZE 30
  1437. X  #define    NUMFONTS 35
  1438. X  
  1439. X  /* element of linked list for each font
  1440. X     The head of list is for the different font NAMES,
  1441. X
  1442. X--- 5,15 -----
  1443. X  #define    FONT_PANE_WIDTH 290
  1444. X  #define    FONT_PANE_HEIGHT 20
  1445. X  #define    NUMFONTS 35
  1446. X+ #else
  1447. X+ #define    FONT_PANE_WIDTH 112
  1448. X+ #define    FONT_PANE_HEIGHT 20
  1449. X+ #define NUMFONTS 6
  1450. X+ #endif
  1451. X  
  1452. X  /* element of linked list for each font
  1453. X     The head of list is for the different font NAMES,
  1454. END_OF_FILE
  1455. if test 1156 -ne `wc -c <'psfonts.h.diff'`; then
  1456.     echo shar: \"'psfonts.h.diff'\" unpacked with wrong size!
  1457. fi
  1458. # end of 'psfonts.h.diff'
  1459. fi
  1460. if test -f 'read.c.diff' -a "${1}" != "-c" ; then 
  1461.   echo shar: Will not clobber existing file \"'read.c.diff'\"
  1462. else
  1463. echo shar: Extracting \"'read.c.diff'\" \(558 characters\)
  1464. sed "s/^X//" >'read.c.diff' <<'END_OF_FILE'
  1465. X*** read.c.old    Thu Feb 15 11:45:44 1990
  1466. X--- read.c    Fri Mar  2 10:51:14 1990
  1467. X***************
  1468. X*** 584,590
  1469. X  
  1470. X      Text_malloc(t);
  1471. X      t->next = NULL;
  1472. X!     n = sscanf(buf,"%*d%d%d%d%d%d%d%lf%d%d%d%d%d %[^\1]",
  1473. X          &t->type, &t->font, &t->size, &t->pen,
  1474. X          &t->color, &t->depth, &t->angle,
  1475. X          &t->style, &t->height, &t->length, 
  1476. X
  1477. X--- 584,590 -----
  1478. X  
  1479. X      Text_malloc(t);
  1480. X      t->next = NULL;
  1481. X!     n = sscanf(buf,"%*d%d%d%d%d%d%d%f%d%d%d%d%d %[^\1]",
  1482. X          &t->type, &t->font, &t->size, &t->pen,
  1483. X          &t->color, &t->depth, &t->angle,
  1484. X          &t->style, &t->height, &t->length, 
  1485. END_OF_FILE
  1486. if test 558 -ne `wc -c <'read.c.diff'`; then
  1487.     echo shar: \"'read.c.diff'\" unpacked with wrong size!
  1488. fi
  1489. # end of 'read.c.diff'
  1490. fi
  1491. if test -f 'read1_3.c.diff' -a "${1}" != "-c" ; then 
  1492.   echo shar: Will not clobber existing file \"'read1_3.c.diff'\"
  1493. else
  1494. echo shar: Extracting \"'read1_3.c.diff'\" \(354 characters\)
  1495. sed "s/^X//" >'read1_3.c.diff' <<'END_OF_FILE'
  1496. X*** read1_3.c.old    Tue Jan 16 17:21:08 1990
  1497. X--- read1_3.c    Thu Mar  1 19:48:50 1990
  1498. X***************
  1499. X*** 451,456
  1500. X          return(NULL);
  1501. X          }
  1502. X      strcpy(t->cstring, buf);
  1503. X!     if (t->size == 0) t->size == 18;
  1504. X      return(t);
  1505. X      }
  1506. X
  1507. X--- 451,456 -----
  1508. X          return(NULL);
  1509. X          }
  1510. X      strcpy(t->cstring, buf);
  1511. X!     if (t->size == 0) t->size = 18;
  1512. X      return(t);
  1513. X      }
  1514. END_OF_FILE
  1515. if test 354 -ne `wc -c <'read1_3.c.diff'`; then
  1516.     echo shar: \"'read1_3.c.diff'\" unpacked with wrong size!
  1517. fi
  1518. # end of 'read1_3.c.diff'
  1519. fi
  1520. if test -f 'resources.h.diff' -a "${1}" != "-c" ; then 
  1521.   echo shar: Will not clobber existing file \"'resources.h.diff'\"
  1522. else
  1523. echo shar: Extracting \"'resources.h.diff'\" \(1438 characters\)
  1524. sed "s/^X//" >'resources.h.diff' <<'END_OF_FILE'
  1525. X*** resources.h.old    Fri Feb 16 15:02:19 1990
  1526. X--- resources.h    Mon Mar 12 11:18:31 1990
  1527. X***************
  1528. X*** 125,130
  1529. X              msg_sw,
  1530. X              panel_sw,
  1531. X              panel2_sw,
  1532. X              fill_panel,
  1533. X              line_thick_panel,
  1534. X              radius_panel,
  1535. X
  1536. X--- 125,131 -----
  1537. X              msg_sw,
  1538. X              panel_sw,
  1539. X              panel2_sw,
  1540. X+             ind_box,    /* thick/radius/fill enclosing widget */
  1541. X              fill_panel,
  1542. X              line_thick_panel,
  1543. X              radius_panel,
  1544. X***************
  1545. X*** 141,146
  1546. X  EXTERN Display        *tool_d;
  1547. X  EXTERN Screen        *tool_s;
  1548. X  EXTERN int        tool_sn;
  1549. X  #define NUMFILLPATS 21
  1550. X  EXTERN int        cur_gcfont[0x10],cur_gcfontsize[0x10];  /* font/size currently in each GC */
  1551. X  EXTERN GC        gc, bold_gc, gccache[0x10], topgc, sidegc,
  1552. X
  1553. X--- 142,149 -----
  1554. X  EXTERN Display        *tool_d;
  1555. X  EXTERN Screen        *tool_s;
  1556. X  EXTERN int        tool_sn;
  1557. X+ 
  1558. X+ #ifndef TFX
  1559. X  #define NUMFILLPATS 21
  1560. X  #else
  1561. X  #define NUMFILLPATS 5
  1562. X***************
  1563. X*** 142,147
  1564. X  EXTERN Screen        *tool_s;
  1565. X  EXTERN int        tool_sn;
  1566. X  #define NUMFILLPATS 21
  1567. X  EXTERN int        cur_gcfont[0x10],cur_gcfontsize[0x10];  /* font/size currently in each GC */
  1568. X  EXTERN GC        gc, bold_gc, gccache[0x10], topgc, sidegc,
  1569. X              fill_gc[NUMFILLPATS],        /* area fill gc's */
  1570. X
  1571. X--- 145,154 -----
  1572. X  
  1573. X  #ifndef TFX
  1574. X  #define NUMFILLPATS 21
  1575. X+ #else
  1576. X+ #define NUMFILLPATS 5
  1577. X+ #endif
  1578. X+ 
  1579. X  EXTERN int        cur_gcfont[0x10],cur_gcfontsize[0x10];  /* font/size currently in each GC */
  1580. X  EXTERN GC        gc, bold_gc, gccache[0x10], topgc, sidegc,
  1581. X              fill_gc[NUMFILLPATS],        /* area fill gc's */
  1582. END_OF_FILE
  1583. if test 1438 -ne `wc -c <'resources.h.diff'`; then
  1584.     echo shar: \"'resources.h.diff'\" unpacked with wrong size!
  1585. fi
  1586. # end of 'resources.h.diff'
  1587. fi
  1588. if test -f 'search.c.diff' -a "${1}" != "-c" ; then 
  1589.   echo shar: Will not clobber existing file \"'search.c.diff'\"
  1590. else
  1591. echo shar: Extracting \"'search.c.diff'\" \(1344 characters\)
  1592. sed "s/^X//" >'search.c.diff' <<'END_OF_FILE'
  1593. X*** search.c.old    Tue Jan 16 17:21:08 1990
  1594. X--- search.c    Tue Mar  6 09:09:23 1990
  1595. X***************
  1596. X*** 52,58
  1597. X          dy = y - e->center.y;
  1598. X          a = e->radiuses.x;
  1599. X          b = e->radiuses.y;
  1600. X!         dis = sqrt((double)(dx*dx + dy*dy));
  1601. X           if (dis == 0) {
  1602. X           *px = e->center.x;
  1603. X           *py = e->center.y;
  1604. X
  1605. X--- 52,62 -----
  1606. X          dy = y - e->center.y;
  1607. X          a = e->radiuses.x;
  1608. X          b = e->radiuses.y;
  1609. X!         /* prevent sqrt(0) core dumps */
  1610. X!         if(dx == 0 && dy == 0)
  1611. X!         dis = 0;    /* so we return below */
  1612. X!         else
  1613. X!             dis = sqrt((double)(dx*dx + dy*dy));
  1614. X           if (dis == 0) {
  1615. X           *px = e->center.x;
  1616. X           *py = e->center.y;
  1617. X***************
  1618. X*** 58,64
  1619. X           *py = e->center.y;
  1620. X           return(e);
  1621. X           }
  1622. X!         r = a * b * dis / sqrt((double) (1.0*b*b*dx*dx + 1.0*a*a*dy*dy));
  1623. X          if (fabs(dis - r) <= tol) {
  1624. X          *px = (int)(r*dx/dis + ((dx < 0) ? -.5 : .5)) + e->center.x;
  1625. X          *py = (int)(r*dy/dis + ((dy < 0) ? -.5 : .5)) + e->center.y;
  1626. X
  1627. X--- 62,71 -----
  1628. X           *py = e->center.y;
  1629. X           return(e);
  1630. X           }
  1631. X!         if(a * dy == 0 && b * dx == 0)
  1632. X!         r = 0;  /* prevent core dumps */
  1633. X!         else
  1634. X!         r = a * b * dis / sqrt((double) (1.0*b*b*dx*dx + 1.0*a*a*dy*dy));
  1635. X          if (fabs(dis - r) <= tol) {
  1636. X          *px = (int)(r*dx/dis + ((dx < 0) ? -.5 : .5)) + e->center.x;
  1637. X          *py = (int)(r*dy/dis + ((dy < 0) ? -.5 : .5)) + e->center.y;
  1638. END_OF_FILE
  1639. if test 1344 -ne `wc -c <'search.c.diff'`; then
  1640.     echo shar: \"'search.c.diff'\" unpacked with wrong size!
  1641. fi
  1642. # end of 'search.c.diff'
  1643. fi
  1644. if test -f 'version.h.diff' -a "${1}" != "-c" ; then 
  1645.   echo shar: Will not clobber existing file \"'version.h.diff'\"
  1646. else
  1647. echo shar: Extracting \"'version.h.diff'\" \(691 characters\)
  1648. sed "s/^X//" >'version.h.diff' <<'END_OF_FILE'
  1649. X*** version.h.old    Tue Feb 20 10:35:24 1990
  1650. X--- version.h    Thu Mar  1 13:18:37 1990
  1651. X***************
  1652. X*** 8,11
  1653. X  */
  1654. X  
  1655. X  #define            FIG_VERSION        "2.0"
  1656. X  #define            PROTOCOL_VERSION    "1.4X"    /* file format */
  1657. X
  1658. X--- 8,14 -----
  1659. X  */
  1660. X  
  1661. X  #define            FIG_VERSION        "2.0"
  1662. X+ #ifndef TFX
  1663. X  #define            PROTOCOL_VERSION    "1.4X"    /* file format */
  1664. X  #else
  1665. X  #define            PROTOCOL_VERSION    "1.4-TFX" /* file format */
  1666. X***************
  1667. X*** 9,11
  1668. X  
  1669. X  #define            FIG_VERSION        "2.0"
  1670. X  #define            PROTOCOL_VERSION    "1.4X"    /* file format */
  1671. X
  1672. X--- 10,15 -----
  1673. X  #define            FIG_VERSION        "2.0"
  1674. X  #ifndef TFX
  1675. X  #define            PROTOCOL_VERSION    "1.4X"    /* file format */
  1676. X+ #else
  1677. X+ #define            PROTOCOL_VERSION    "1.4-TFX" /* file format */
  1678. X+ #endif
  1679. END_OF_FILE
  1680. if test 691 -ne `wc -c <'version.h.diff'`; then
  1681.     echo shar: \"'version.h.diff'\" unpacked with wrong size!
  1682. fi
  1683. # end of 'version.h.diff'
  1684. fi
  1685. if test -f 'xtra.c.diff' -a "${1}" != "-c" ; then 
  1686.   echo shar: Will not clobber existing file \"'xtra.c.diff'\"
  1687. else
  1688. echo shar: Extracting \"'xtra.c.diff'\" \(1724 characters\)
  1689. sed "s/^X//" >'xtra.c.diff' <<'END_OF_FILE'
  1690. X*** xtra.c.old    Thu Feb 22 17:08:52 1990
  1691. X--- xtra.c    Mon Mar 12 13:26:43 1990
  1692. X***************
  1693. X*** 125,130
  1694. X  
  1695. X  /* grey images for fill patterns */
  1696. X  
  1697. X  static char  fill_images[NUMFILLPATS][8] = {
  1698. X     {0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00},
  1699. X     {0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00},
  1700. X
  1701. X--- 125,131 -----
  1702. X  
  1703. X  /* grey images for fill patterns */
  1704. X  
  1705. X+ #ifndef TFX
  1706. X  static char  fill_images[NUMFILLPATS][8] = {
  1707. X     {0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00},
  1708. X     {0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00},
  1709. X***************
  1710. X*** 148,153
  1711. X     {0x77, 0xff, 0x7f, 0xbe, 0x7f, 0xff, 0x77, 0xaa},
  1712. X     {0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff},
  1713. X     };
  1714. X  
  1715. X  /* create the gc's for area fill (PAINT and ERASE) */
  1716. X  
  1717. X
  1718. X--- 149,163 -----
  1719. X     {0x77, 0xff, 0x7f, 0xbe, 0x7f, 0xff, 0x77, 0xaa},
  1720. X     {0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff},
  1721. X     };
  1722. X+ #else
  1723. X+ static char  fill_images[NUMFILLPATS][8] = {
  1724. X+    {0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff},
  1725. X+    {0x55, 0xaa, 0x77, 0xaa, 0x55, 0xaa, 0xdd, 0xaa},
  1726. X+    {0x55, 0x00, 0x55, 0x00, 0x55, 0x00, 0x55, 0x00},
  1727. X+    {0x00, 0x44, 0x00, 0x10, 0x00, 0x44, 0x00, 0x00},
  1728. X+    {0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00},
  1729. X+    };
  1730. X+ #endif
  1731. X  
  1732. X  /* create the gc's for area fill (PAINT and ERASE) */
  1733. X  
  1734. X***************
  1735. X*** 420,443
  1736. X          }
  1737. X      }
  1738. X  
  1739. X- #ifdef  sparc
  1740. X- 
  1741. X- #undef cfree
  1742. X- #undef free
  1743. X- 
  1744. X- #include <stdio.h>
  1745. X- 
  1746. X- FREE ( x )    /*-- disable free --*/
  1747. X-     char *x ;
  1748. X- {
  1749. X-     free(x);
  1750. X-     /* fprintf( stderr, "FREE -- %8x\n", x ) ; */
  1751. X- }
  1752. X- CFREE ( x )   /*-- disable cfree --*/
  1753. X-     char *x ;
  1754. X- {
  1755. X-     cfree(x);
  1756. X-     /* fprintf( stderr, "FREE -- %8x\n", x ) ; */
  1757. X- }
  1758. X- 
  1759. X- #endif  sparc
  1760. X
  1761. X--- 430,432 -----
  1762. X          }
  1763. X      }
  1764. X  
  1765. END_OF_FILE
  1766. if test 1724 -ne `wc -c <'xtra.c.diff'`; then
  1767.     echo shar: \"'xtra.c.diff'\" unpacked with wrong size!
  1768. fi
  1769. # end of 'xtra.c.diff'
  1770. fi
  1771. echo shar: End of archive 1 \(of 3\).
  1772. cp /dev/null ark1isdone
  1773. MISSING=""
  1774. for I in 1 2 3 ; do
  1775.     if test ! -f ark${I}isdone ; then
  1776.     MISSING="${MISSING} ${I}"
  1777.     fi
  1778. done
  1779. if test "${MISSING}" = "" ; then
  1780.     echo You have unpacked all 3 archives.
  1781.     rm -f ark[1-9]isdone
  1782. else
  1783.     echo You still need to unpack the following archives:
  1784.     echo "        " ${MISSING}
  1785. fi
  1786. ##  End of shell archive.
  1787. exit 0
  1788.  
  1789. dan
  1790. -----------------------------------------------------------
  1791.             O'Reilly && Associates
  1792.         argv@sun.com / argv@ora.com
  1793.        632 Petaluma Ave, Sebastopol, CA 95472 
  1794.      800-338-NUTS, in CA: 800-533-NUTS, FAX 707-829-0104
  1795.     Opinions expressed reflect those of the author only.
  1796.